import slideShowModel from '@/models/slideShow';
import slde from '@/services/noticeService';
import slideShowService from '@/services/slideShowService';
import { action, computed, observable } from 'mobx';

export default class SlideShowStore {

  // @observable
  // pageSize?: number = 5;
  // @observable
  // pageNumber?: number = 1;
  @observable
  sequence?: number;
  @observable
  @observable
 slideShowList?: slideShowModel[];


  // @observable
  // slideShowList?: Array<slideShowModel>;
  @observable
  slideShowListLoading: boolean = false;

  @action
  async getCarouselList() {
    let list = await slideShowService.slideShowList({ type: 0 });
    this.slideShowList = list?.slidedata;
  }

  // @action
  // async listNotice() {
  //   this.slideShowListLoading = true;
  //   this.slideShowList = (await slideShowService.slideShowList(this.sequence)).dataList;
  //   this.slideShowListLoading = false;
  //   console.log(this.slideShowList);

  // }
}

export const slideShowStore = new SlideShowStore();
